home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Software Vault: The Gold Collection
/
Software Vault - The Gold Collection (American Databankers) (1993).ISO
/
cdr35
/
rnet200f.zip
/
RNETPACK.DOC
< prev
next >
Wrap
Text File
|
1993-06-02
|
13KB
|
210 lines
-------------------------------------------------------------------------------
Using RNETPACK.LST
-------------------------------------------------------------------------------
Here's the problem: We all need to pack our messagebases fairly heavily due
to the message traffic in echo conferences. However, packing ALL of your
messagebases all of the time it not only time consuming, it also causes more
wear and tear on your drives than needed.
Here's the solution: RNET can check your conferences (any or all) and
determine when they reach a specified message count. When they reach that
level, you can then pack the messagebase to a lower count. The result is
that your messagebases are packed less often, and only when *needed*.
When you've got everything setup, RNET creates a batch file that calls the
packing program of your choice with the params of your choice. All you
need to do is call the resulting batch file to pack conferences that need
packing (it does not pack conferences that have not made it to the message
limit specified). If the batch file does not exist, there are no
conferences that need packing. It's that simple.
Creating RNETPACK.LST
Using the text editor of your choice, create RNETPACK.LST with the following
information:
<conf#> <max messages> <packing cmd>
<conf#> = a conference number or range of numbers.
<max messages> = max messages allowed before packing required.
<packing cmd> = commandline to write to batch to do the packing.
Example RNETPACK.LST file:
┌─────────────────────────────────────────────────────────────────────────────┐
│ 0 750 pcbpack /AREA:@CONFNUM@ /MA:500 /MM:200 /NC /FA /KB /KD /QUIET │
│ 1-249 750 pcbpack /AREA:@CONFNUM@ /MA:500 /MM:50 /NC /FA /KB /KD /QUIET │
│ 250-500 500 pcbpack /AREA:@CONFNUM@ /MA:250 /MM:50 /NC /FA /KB /KD /QUIET │
└─────────────────────────────────────────────────────────────────────────────┘
Conference 0 (main board) is packed only when it has more than 750 messages
and it will be packed down to 500 messages (min of 200).
Conferences 1 to 249 are only packed when they exceed 750 messages and are
packed down to 500 messages (min of 50 kept).
Conferences 250 to 500 are packed when they have more than 500 messages and
are packed down to a max of 250 (min of 50).
The packing will actually be done by PCBPACK.EXE (please see the PCBoard
documentation for operation of PCBPACK.EXE). You could "call pack.bat" or
do anything else you wanted. Whatever is specified for the packing command
is written to RNETPACK.BAT.
Note the "@CONFNUM@" included in the packing line. @CONFNUM@ will be
replaced with the conference number that needs to be packed. You may also
use @CONFNAME@ (name of the conference, like "Main Board") and @MSGFILE@
(full path name of the messages file, such as "D:\CONF\MSGS") or any
environment variables or other RNET @..@ codes.
NOTE: If any conferences need to be packed (ie, if RNETPACK.BAT is created),
RNET will always put the following at the beginning of the file:
┌─────────────────────────────────────┐
│ @echo off │
│ echo ** Auto-pack batch created... │
│ %PCBDRIVE% │
│ CD %PCBDIR% │
│ (packing lines go here...) │
└─────────────────────────────────────┘
The %PCBDRIVE% and CD %PCBDIR% is done since PCBPACK.EXE requires you to be
in the PCB directory to operate correctly.
You can have the batch file do whatever you want... for testing purposes,
you could use a RNETPACK.LST file to just do echo statements as:
┌─────────────────────────────────────────────────────────────────────────────┐
│ 0 750 echo Conference @CONFNAME@ (@CONFNUM@) has over 750 msgs! │
│ 20-50 500 echo Conference @CONFNAME@ (@CONFNUM@) has over 500 msgs! │
│ 300-302 100 echo Conference @CONFNAME@ (@CONFNUM@) has over 100 msgs! │
└─────────────────────────────────────────────────────────────────────────────┘
This might result in RNETPACK.BAT:
┌─────────────────────────────────────────────────────────────────────────────┐
│@echo off │
│echo ** Auto-pack batch created by RNET Thu May 20 1993 │
│C: │
│CD \PCB │
│echo Conference Main Board (0) has over 750 msgs! │
│echo Conference AtlSysop (21) has over 500 msgs! │
│echo Conference Usenet_bad (47) has over 500 msgs! │
│echo Conference sci.astro (300) has over 100 msgs! │
│echo Conference sci.astro.hst (301) has over 100 msgs! │
│echo Conference sci.astro.fit (302) has over 100 msgs! │
└─────────────────────────────────────────────────────────────────────────────┘
You can even do something sneaky like build a cheap CNFN screen using:
┌─────────────────────────────────────────────────────────────────────────────┐
│ 0-25 0 echo @CONFNUM@ @POS:10@ @CONFNAME@ @POS:30@(local) >>C:\JUNK │
│ 100-149 0 echo @CONFNUM@ @POS:10@ @CONFNAME@ @POS:30@(ILink) >>C:\JUNK │
│ 150-199 0 echo @CONFNUM@ @POS:10@ @CONFNAME@ @POS:30@(SmartNet) >>C:\JUNK │
│ 200-249 0 echo @CONFNUM@ @POS:10@ @CONFNAME@ @POS:30@(RIME) >>C:\JUNK │
│ 250-500 0 echo @CONFNUM@ @POS:10@ @CONFNAME@ @POS:30@(Usenet) >>C:\JUNK │
│; all conferences are listed that have any messages at all (ie, over 0) │
│; @X color codes could be added as well... │
└─────────────────────────────────────────────────────────────────────────────┘
This might result in RNETPACK.BAT:
┌─────────────────────────────────────────────────────────────────────────────┐
│@echo off │
│echo ** Auto-pack batch created by RNET Thu May 20 1993 │
│C: │
│CD \PCB │
│echo 0 @POS:10@ Main Board @POS:30@(local) >>C:\JUNK │
│echo 1 @POS:10@ ChitChat @POS:30@(local) >>C:\JUNK │
│echo 2 @POS:10@ NASA @POS:30@(local) >>C:\JUNK │
│... │
│echo 300 @POS:10@ sci.astro @POS:30@(Usenet) >>C:\JUNK │
└─────────────────────────────────────────────────────────────────────────────┘
Note that the @POS:xx@ is a PCBoard 15 feature. Now, if you run the above
batch (making sure to delete C:\JUNK if it already exists), a quick and
dirty CNFN screen can be created. This example doesn't actually pack any
message bases, it's just an example of the kinds of things you can do.
RNET can create the RNETPACK.BAT file automatically -or- you can tell it
when to create it via the commandline. To have RNET create it
automatically, add a AUTO_PACK=YES to your .CFG. Then, after RNET is done
with everything else during an IMPORT, it will check the conferences as
instructed in the RNETPACK.LST file, building the RNETPACK.BAT as needed.
Note: RNET doesn't actually run the batch file... it just creates it.
If you want to TELL RNET when to create the batch, use AUTO_PACK=NO
(which is the default) and run RNET PACK <hostid.cfg> when you want
it to do the checking (ie, use "PACK" in place of IMPORT or EXPORT).
Example EVENT batch file for doing several mail events and then checking
for packing:
┌──────────────────────────────────────────────────────────────────────┐
│ @echo off │
│ echo ** RNET EVENT ** │
│ D: │
│ cd \RNET │
│ │
│ rem Export new messages for three hosts we call │
│ RNET EXPORT ARGOSY │
│ RNET EXPORT ADBUS │
│ RNET EXPORT TRP │
│ │
│ rem Call hosts and upload REPs, download QWKs │
│ TELIX -sARGOSY │
│ TELIX -sADBUS │
│ TELIX -sTRP │
│ │
│ rem Import new QWK packets if they exist │
│ RNET IMPORT ARGOSY │
│ RNET IMPORT ADBUS │
│ RNET IMPORT TRP │
│ │
│ rem Check for messagebases that need packing (any <hostid> will do) │
│ RNET PACK TRP │
│ │
│ rem Do actual messagebase packing by calling auto-pack batch file │
│ if exist d:\rnet\RNETPACK.BAT call d:\rnet\RNETPACK.BAT │
│ │
│ rem Delete auto-pack batch file │
│ if exist d:\rnet\RNETPACK.BAT del d:\rnet\RNETPACK.BAT │
│ │
│ rem Restart BBS (end of event) │
│ BOARD.BAT │
└──────────────────────────────────────────────────────────────────────┘
I personally have AUTO_PACK=NO and have a specific batch file that is called
to do my packing during the 4am event via: " CALL K:\RNET\PACK.BAT " which
has:
┌─────────────────────────────────────────────────┐
│ @echo off │
│ k: │
│ cd \rnet │
│ RNET PACK TRP.CFG │
│ if exist RNETPACK.BAT RNETPACK │
└─────────────────────────────────────────────────┘
Since I used a "call k:\rnet\pack.bat" in my 4AM batch, when either
K:\RNET\PACK.BAT ends (ie, nothing to pack) or K:\RNET\RNETPACK.BAT ends
(after packing), control is returned to the calling batch (EVENT.BAT).
-------------------------------------------------------------------------------
Advanced Operation
-------------------------------------------------------------------------------
When you've got all that figured out, guess what? Not only can you change
the name of the RNETPACK.LST and RNETPACK.BAT filenames, you can use
different names to have it do different things on different days! You might
want to only check conferences on MON, WED, FRI... To do so, simply add
PACK_LIST=@WEEKDAY@.LST and create a MON.LST, WED.LST, and FRI.LST files. If
it's Tuesday, RNET will look for TUE.LST -- it doesn't do anything if it
doesn't find it. If you use an environment variable to give RNET a "home"
other than the current directory (ie, you use QWIKMAIL= or RNET=), and want
your weekday.lst file to be stored there, use PACK_LIST=@HOME@@WEEKDAY@.LST
The RNETPACK.BAT filename can also be overridden with PACK_BAT=<filename>.
If you want a different packing .LST for each host you call, use the
following in each <hostid>.CFG file:
PACK_LIST=@HOME@@HOSTID@.LST ; use <hostid>.lst for packing rules
PACK_BAT =@HOME@@HOSTID@.BAT ; create <hostid>.bat to do actual packing
The default for PACK_LIST= is @HOME@RNETPACK.LST and the default for
PACK_BAT= is @HOME@RNETPACK.BAT. AUTO_PACK defaults to OFF.
-------------------------------------------------------------------------------